package tsing.javase.mapstruct_use;

import com.alibaba.fastjson.JSON;
import lombok.Data;

/**
 * @Date 2024/9/20 11:26
 * @Author Tsing
 */
@Data
public class StudentDO {


    private Long id;

    private String name;

    private Integer gender;

    private Integer age;



    public static void main(String[] args) {

        MyStudent myStudent = new MyStudent();
        myStudent.setId(1L);
        myStudent.setName("清平");
        myStudent.setAge(28);
        myStudent.setGender(1);

        StudentDO studentDO = StudentDOConvert.INSTANCE.mystdConvert(myStudent);
        System.out.println(JSON.toJSONString(studentDO));
    }
}
